<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <title>JSDoc: Class: Commit</title>
    
    <script src="scripts/prettify/prettify.js"> </script>
    <script src="scripts/prettify/lang-css.js"> </script>
    <!--[if lt IE 9]>
      <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css">
    <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css">
</head>

<body>

<div id="main">
    
    <h1 class="page-title">Class: Commit</h1>
    
    



<section>
    
<header>
    <h2>
    Commit
    </h2>
    
</header>  

<article>
    <div class="container-overview">
    
    
    
        
<dt>
    <h4 class="name" id="Commit"><span class="type-signature"></span>new Commit<span class="signature">(options)</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Commit</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Commit.html">Commit</a></li></ul>
    
    
    
        <h5>Parameters:</h5>
        

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>options</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
            
            
            
            <td class="description last"><p>Commit options</p>
                <h6>Properties</h6>
                

<table class="params">
    <thead>
	<tr>
		
		<th>Name</th>
		
		
		<th>Type</th>
		
		
		<th>Argument</th>
		
		
		
		<th>Default</th>
		
		
		<th class="last">Description</th>
	</tr>
	</thead>
	
	<tbody>
	
	
        <tr>
            
                <td class="name"><code>parent</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="GitGraph.html">GitGraph</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>GitGraph constructor</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>x</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Position X (dot)</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>y</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Position Y (dot)</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>color</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Master color (dot &amp; message)</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>arrowDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Add a arrow under commit dot</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>author</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.parent.author
                
                </td>
            
            
            <td class="description last"><p>Author name &amp; email</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>date</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Date of commit, default is now</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>detail</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>DOM Element of detail part</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>sha1</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Sha1, default is a random short sha1</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>parentCommit</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="Commit.html">Commit</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Parent commit</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>type</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    ("mergeCommit"|null)
                
                </td>
            
            
            <td class="description last"><p>Type of commit</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tag</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Tag of the commit</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tagColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    options.color
                
                </td>
            
            
            <td class="description last"><p>Color of the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tagFont</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.tag.font
                
                </td>
            
            
            <td class="description last"><p>Font of the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>displayTagBox</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    true
                
                </td>
            
            
            <td class="description last"><p>If true, display a box around the tag</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dotColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    options.color
                
                </td>
            
            
            <td class="description last"><p>Specific dot color</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dotSize</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.dot.size
                
                </td>
            
            
            <td class="description last"><p>Dot size</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dotStrokeWidth</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.dot.strokeWidth
                
                </td>
            
            
            <td class="description last"><p>Dot stroke width</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>dotStrokeColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Number</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.dot.strokeColor
                
                </td>
            
            
            <td class="description last"></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>message</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    "He doesn't like George Michael! Boooo!"
                
                </td>
            
            
            <td class="description last"><p>Commit message</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    options.color
                
                </td>
            
            
            <td class="description last"><p>Specific message color</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageFont</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.message.font
                
                </td>
            
            
            <td class="description last"><p>Font of the message</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.message.display
                
                </td>
            
            
            <td class="description last"><p>Commit message display policy</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageAuthorDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.message.displayAuthor
                
                </td>
            
            
            <td class="description last"><p>Commit message author policy</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageBranchDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.message.displayBranch
                
                </td>
            
            
            <td class="description last"><p>Commit message author policy</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>messageHashDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.commit.message.displayHash
                
                </td>
            
            
            <td class="description last"><p>Commit message hash policy</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>labelColor</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    options.color
                
                </td>
            
            
            <td class="description last"><p>Specific label color</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>labelFont</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">String</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    this.template.branch.labelFont
                
                </td>
            
            
            <td class="description last"><p>Font used for labels</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>tooltipDisplay</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Boolean</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                    true
                
                </td>
            
            
            <td class="description last"><p>Tooltip message display policy</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>onClick</code></td>
            
            
            <td class="type">
            
                
<span class="param-type"><a href="global.html#commitCallback">commitCallback</a></span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>OnClick event for the commit dot</p></td>
        </tr>
	
	
	
        <tr>
            
                <td class="name"><code>representedObject</code></td>
            
            
            <td class="type">
            
                
<span class="param-type">Object</span>


            
            </td>
            
            
                <td class="attributes">
                
                    &lt;optional><br>
                
                    
                
                    
                
                </td>
            
            
            
                <td class="default">
                
                </td>
            
            
            <td class="description last"><p>Any object which is related to this commit. Can be used in onClick or the formatter. Useful to bind the commit to external objects such as database id etc.</p></td>
        </tr>
	
	
	</tbody>
</table>
            </td>
        </tr>
	
	
	</tbody>
</table>
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line1021">line 1021</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

    
    </div>
    
    
    
    
    
    
    
    
    
    
    
    
    
    
        <h3 class="subsection-title">Methods</h3>
        
        <dl>
            
<dt>
    <h4 class="name" id="arrow"><span class="type-signature"></span>arrow<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Render a arrow before commit</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Commit.html">Commit</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line1168">line 1168</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        
            
<dt>
    <h4 class="name" id="render"><span class="type-signature"></span>render<span class="signature">()</span><span class="type-signature"></span></h4>
    
    
</dt>
<dd>
    
    
    <div class="description">
        <p>Render the commit</p>
    </div>
    

    
    
    
        <h5>This:</h5>
        <ul><li><a href="Commit.html">Commit</a></li></ul>
    
    
    
    
    
<dl class="details">
    
        
    
    
    

    
    
    
    
    
    
    
    
    
    
    
    
    
    <dt class="tag-source">Source:</dt>
    <dd class="tag-source"><ul class="dummy"><li>
        <a href="gitgraph.js.html">gitgraph.js</a>, <a href="gitgraph.js.html#line1069">line 1069</a>
    </li></ul></dd>
    
    
    
    
    
    
    
</dl>

    
    

    

    
    
    
    
    
    
    
</dd>

        </dl>
    
    
    
    
    
</article>

</section>  




</div>

<nav>
    <h2><a href="index.html">Index</a></h2><h3>Classes</h3><ul><li><a href="Branch.html">Branch</a></li><li><a href="Commit.html">Commit</a></li><li><a href="GitGraph.html">GitGraph</a></li><li><a href="Tag.html">Tag</a></li><li><a href="Template.html">Template</a></li></ul><h3>Global</h3><ul><li><a href="global.html#_assignTagOptionsToCommit">_assignTagOptionsToCommit</a></li><li><a href="global.html#_booleanOptionOr">_booleanOptionOr</a></li><li><a href="global.html#_clone">_clone</a></li><li><a href="global.html#_drawTextBG">_drawTextBG</a></li><li><a href="global.html#_emitEvent">_emitEvent</a></li><li><a href="global.html#_getFontHeight">_getFontHeight</a></li><li><a href="global.html#_getLast">_getLast</a></li><li><a href="global.html#_getParentCommitFromBranch">_getParentCommitFromBranch</a></li><li><a href="global.html#_getScale">_getScale</a></li><li><a href="global.html#_isHorizontal">_isHorizontal</a></li><li><a href="global.html#_isNullOrUndefined">_isNullOrUndefined</a></li><li><a href="global.html#_isObject">_isObject</a></li><li><a href="global.html#_isVertical">_isVertical</a></li></ul>
</nav>

<br clear="both">

<footer>
    Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.2.2</a> on Fri Jan 06 2017 09:40:41 GMT+0100 (CET)
</footer>

<script> prettyPrint(); </script>
<script src="scripts/linenumber.js"> </script>
</body>
</html>